import Vue from "vue";
import Vuex from "vuex";
import createPersistedState from 'vuex-persistedstate'
Vue.use(Vuex);

export default new Vuex.Store({
  plugins: [
    createPersistedState()
  ],
  state: {
    userInfo: {}, //用户信息
    AccessToken: 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE2OTQzOTgxMzksInVzZXJuYW1lIjoiNjIyMjAxMTk5MDAwMDAwMDAwIn0.9QU2P7erjDRVXvxUStB-Lv1rJJOYmtrZUg8Sj594uPA',//AccessToken
    dataList: [], //企业档案信息
    dataLists: [], //企业档案选择信息
  },
  getters: {},
  mutations: {
    userInfo: (state, detail) => {
      state.userInfo = detail
    },
    AccessToken: (state, detail) => {
      state.AccessToken = detail
    },
    dataList: (state, detail) => {
      state.dataList = detail
    },
    dataLists: (state, detail) => {
      state.dataLists = detail
    },
  },
  actions: {},
  modules: {}
});
